package com.unknowpupil.web.service;

import com.unknowpupil.web.base.BaseCrudService;
import com.unknowpupil.web.base.Result;
import com.unknowpupil.web.component.wallet.entity.CoinWallet;
import com.unknowpupil.web.domain.Account;
import com.unknowpupil.web.domain.AccountInfo;
import com.unknowpupil.web.exception.MxException;
import com.unknowpupil.web.mapper.AccountMapper;

/**
 * @Classname: ${NAME}
 * @Author: <a> w10g </a>
 * @CreateDate: Create in 2019/11/6 14:20
 * @Description:
 * @Version: 1.0
 */
public interface IAccountService extends BaseCrudService<Account> {

    /**
     * 注册，创建钱包
      * @param userName
     * @param password
     * @param invitationCode
     * @return
     */
    Result createWallet(String userName, String password, String invitationCode);

    /**
     * 根据资源获取密钥
     * @param password
     * @param source
     * @return
     * @throws MxException
     */
    Result findSecretKeyBySource(String password, String source) throws MxException;

    /**
     * 分支实体类
     * @param userName
     * @param password
     * @return
     * @throws MxException
     */
    Account createAccount(String userName, String password) throws MxException;

    /**
     * 获取用户信息
     * @param id
     * @return
     */
    Result getAccount(String id);

    /**
     * 根据地址获取用户名
     * @return
     */

}
